package com.jims.master.modules.doctor.netHosptial.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.jims.master.common.persistence.DataEntity;
import org.hibernate.validator.constraints.Length;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * 处方主表Entity
 * @author xueyx
 * @version 2017-04-06
 */
public class NetPrescMain extends DataEntity<NetPrescMain> {

	private static final long serialVersionUID = 1L;
	private String clinicId;		// 门诊单号
	private Date visitDate;		// 就诊日期
	private String visitNo;		// 就诊序号
	private String patientId;		// 病人标识号
	private String visitId;		// 本次住院标识
	private String serialNo;		// 流水号
	private String ordersId;		// 医嘱id
	private String prescNo;		// 处方序号
	private String confirmFlag;		// 发药标志
	private String chargeFllag;		// 收费标志
	private String implementDept;		// 发药药房
	private String prescAttr;		// 处方属性
	private String itemClass;		// 处方分类
	private String prescStatus;		// 是否已保存至医嘱表

	List<NetPresc> list = new ArrayList<NetPresc>();

	public NetPrescMain() {
		super();
	}

	public NetPrescMain(String id){
		super(id);
	}

	@Length(min=0, max=64, message="门诊单号长度必须介于 0 和 64 之间")
	public String getClinicId() {
		return clinicId;
	}

	public void setClinicId(String clinicId) {
		this.clinicId = clinicId;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getVisitDate() {
		return visitDate;
	}

	public void setVisitDate(Date visitDate) {
		this.visitDate = visitDate;
	}
	
	@Length(min=0, max=5, message="就诊序号长度必须介于 0 和 5 之间")
	public String getVisitNo() {
		return visitNo;
	}

	public void setVisitNo(String visitNo) {
		this.visitNo = visitNo;
	}
	
	@Length(min=0, max=64, message="病人标识号长度必须介于 0 和 64 之间")
	public String getPatientId() {
		return patientId;
	}

	public void setPatientId(String patientId) {
		this.patientId = patientId;
	}
	
	@Length(min=0, max=64, message="本次住院标识长度必须介于 0 和 64 之间")
	public String getVisitId() {
		return visitId;
	}

	public void setVisitId(String visitId) {
		this.visitId = visitId;
	}
	
	@Length(min=0, max=10, message="流水号长度必须介于 0 和 10 之间")
	public String getSerialNo() {
		return serialNo;
	}

	public void setSerialNo(String serialNo) {
		this.serialNo = serialNo;
	}
	
	@Length(min=0, max=64, message="医嘱id长度必须介于 0 和 64 之间")
	public String getOrdersId() {
		return ordersId;
	}

	public void setOrdersId(String ordersId) {
		this.ordersId = ordersId;
	}
	
	@Length(min=0, max=64, message="处方序号长度必须介于 0 和 64 之间")
	public String getPrescNo() {
		return prescNo;
	}

	public void setPrescNo(String prescNo) {
		this.prescNo = prescNo;
	}
	
	@Length(min=0, max=1, message="发药标志长度必须介于 0 和 1 之间")
	public String getConfirmFlag() {
		return confirmFlag;
	}

	public void setConfirmFlag(String confirmFlag) {
		this.confirmFlag = confirmFlag;
	}
	
	@Length(min=0, max=1, message="收费标志长度必须介于 0 和 1 之间")
	public String getChargeFllag() {
		return chargeFllag;
	}

	public void setChargeFllag(String chargeFllag) {
		this.chargeFllag = chargeFllag;
	}
	
	@Length(min=0, max=10, message="发药药房长度必须介于 0 和 10 之间")
	public String getImplementDept() {
		return implementDept;
	}

	public void setImplementDept(String implementDept) {
		this.implementDept = implementDept;
	}
	
	@Length(min=0, max=10, message="处方属性长度必须介于 0 和 10 之间")
	public String getPrescAttr() {
		return prescAttr;
	}

	public void setPrescAttr(String prescAttr) {
		this.prescAttr = prescAttr;
	}
	
	@Length(min=0, max=10, message="处方分类长度必须介于 0 和 10 之间")
	public String getItemClass() {
		return itemClass;
	}

	public void setItemClass(String itemClass) {
		this.itemClass = itemClass;
	}
	
	@Length(min=0, max=1, message="是否已保存至医嘱表长度必须介于 0 和 1 之间")
	public String getPrescStatus() {
		return prescStatus;
	}

	public void setPrescStatus(String prescStatus) {
		this.prescStatus = prescStatus;
	}

	public List<NetPresc> getList() {
		return list;
	}

	public void setList(List<NetPresc> list) {
		this.list = list;
	}
}